package com.jeecg.arch.module.action;

import javax.servlet.http.HttpServletRequest;

import com.jeecg.arch.base.Action;
import com.jeecg.arch.base.beans.ActionForm;
import com.jeecg.arch.module.beans.LoginBean;
import com.jeecg.arch.utils.XmlBean;

public class RegisterAction implements Action {

	public String execute(HttpServletRequest request, XmlBean xmlBean,
			Object obj) {

		String forward = "404.jsp";

		LoginBean loginBean = (LoginBean) obj;

		if ("success".equals(request.getParameter("sign"))) {

			forward = xmlBean.getActionForWard().get("success");

		} else {

			forward = xmlBean.getActionForWard().get("error");

		}

		request.setAttribute("loginBean", loginBean);

		return forward;
	}
}
